/*    */ package com.wgcloud.common;
/*    */ 
/*    */ import org.springframework.beans.BeansException;
/*    */ import org.springframework.context.ApplicationContext;
/*    */ import org.springframework.context.ApplicationContextAware;
/*    */ import org.springframework.stereotype.Component;
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ @Component
/*    */ public class ApplicationContextHelper
/*    */   implements ApplicationContextAware
/*    */ {
/*    */   private static ApplicationContext applicationContext;
/*    */   
/*    */   public void setApplicationContext(ApplicationContext applicationContext1) throws BeansException {
/* 22 */     applicationContext = applicationContext1;
/*    */   }
/*    */   
/*    */   public static ApplicationContext getApplicationContext() {
/* 26 */     return applicationContext;
/*    */   }
/*    */ 
/*    */   
/*    */   public static <T> T getBean(Class<T> clazz) {
/* 31 */     return (T)applicationContext.getBean(clazz);
/*    */   }
/*    */ }


/* Location:              /Users/zhangyongxin/soft-install/wgcloud/wgcloud-v3.3.5/server/bank/wgcloud-server-release.jar!/BOOT-INF/classes/com/wgcloud/common/ApplicationContextHelper.class
 * Java compiler version: 8 (52.0)
 * JD-Core Version:       1.1.3
 */